
import  request from '@/utils/axios/index.js'
const api_name = '/system/user';

export const findByPage = (page,limit,params)=>{
    return request.get({
        url:`${api_name}/getListByPage/${page}/${limit}`,
        params
    })
}

export const updateUserStatus = (uid,status)=>{
    return request.get({url:`${api_name}/update/status/${uid}/${status}`})
}

export const resetPassword = uid => {
    return request.get({url:`${api_name}/reset/${uid}`});
}

export const deleteUser = uid=>{
    return request.get({url:`${api_name}/deleted/${uid}`});
}

export const saveUser = data => {
    return request.post(
        {
            url:`${api_name}/save`,
            ContentType:'application/x-www-form-urlencoded',
            data
        }
    )
}